<?php
class Application_Model_Countries extends Zend_Db_Table{
	protected $_name = 'countries';

	const DEFAULT_COUNTRY = 1;

	public function getSelect(){
		try{
			$sql = $this->select()->setIntegrityCheck(false)
						->from($this->_name, array('id', 'name'))
						->where('deleted = 0');

			$result = $this->getAdapter()->fetchPairs($sql);

			if( $result )
				return $result;
			else
				return array();
		}
		catch(Zend_Exception $e){
			return array();
		}
	}

}